//
//  ZZNavgationViewController.m
//  ZuZuBao
//
//  Created by Felix on 2024/4/8.
//

#import "ZZNavgationViewController.h"

@interface ZZNavgationViewController ()

@end

@implementation ZZNavgationViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    self.modalPresentationStyle = UIModalPresentationFullScreen;
    self.view.backgroundColor = [UIColor whiteColor];
    
    // 获取当前视图控制器的导航条
    UINavigationBar *navigationBar = self.navigationController.navigationBar;
    // 设置导航条背景色
    navigationBar.backgroundColor = [UIColor whiteColor]; // 替换为你想要的颜色
      
    
    // 1. 创建自定义的返回按钮
//    UIImage *backButtonImage = [UIImage imageNamed:@"arrow_left_icon"]; // 使用你的图片名替换 "your_image_name"
//    UIButton *backButton = [UIButton buttonWithType:UIButtonTypeCustom];
//    [backButton setBackgroundImage:backButtonImage forState:UIControlStateNormal];
//    [backButton addTarget:self action:@selector(backAction) forControlEvents:UIControlEventTouchUpInside];
//    backButton.frame = CGRectMake(0, 0, 40, 40);
//      
//    UIBarButtonItem *customBackButton = [[UIBarButtonItem alloc] initWithCustomView:backButton];
//      
//    // 2. 设置导航控制器的导航项的左按钮
//    self.navigationItem.leftBarButtonItem = customBackButton;
      
    [[UINavigationBar appearance] setTintColor:k333Color];//before ios11.0
    // 隐藏灰色线
    self.navigationController.navigationBar.shadowImage = [UIImage new];
    
}

- (void)backAction {
    [self.navigationController popViewControllerAnimated:YES];
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
